package com.friend.entity.entity.base;

import com.baomidou.mybatisplus.annotation.*;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import lombok.experimental.Accessors;
import org.springframework.data.solr.core.mapping.SolrDocument;

import java.io.Serializable;
import java.time.LocalDate;
import java.time.LocalDateTime;

/**
 * <p>
 * 
 * </p>
 *
 * @author friend
 * @since 2019-11-22
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@Builder
@AllArgsConstructor
@RequiredArgsConstructor(staticName = "of")
@TableName("t_film_info")
@ApiModel(value="FilmInfo对象", description="")
@SolrDocument
public class FilmInfo extends Model<FilmInfo> {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "ID")
    @TableId(value = "id", type = IdType.AUTO)
    private String id;

    @ApiModelProperty(value = "名称")
    @TableField("film_name")
    private String filmName;

    @ApiModelProperty(value = "别名")
    @TableField("film_alias")
    private String filmAlias;

    @ApiModelProperty(value = "海报 多个海报之间用逗号隔开 一般只有一张海报 只存放图片名称默认图片格式都jpg")
    @TableField("film_poster")
    private String filmPoster;

    @ApiModelProperty(value = "剧照 多个剧照之间用逗号隔开 只存放图片名称默认图片格式都jpg")
    @TableField("film_img")
    private String filmImg;

    @ApiModelProperty(value = "预告片 多预告片之间用逗号隔开 只存放视频名称默认图片格式都mp4")
    @TableField("film_video")
    private String filmVideo;

    @ApiModelProperty(value = "导演")
    @TableField("film_regisseur")
    private String filmRegisseur;

    @ApiModelProperty(value = "编剧")
    @TableField("film_writer")
    private String filmWriter;

    @TableField("film_lang")
    private String filmLang;

    @ApiModelProperty(value = "主演")
    @TableField("film_leading")
    private String filmLeading;

    @ApiModelProperty(value = "影片类型")
    @TableField("film_type")
    private String filmType;

    @ApiModelProperty(value = "地区")
    @TableField("film_area")
    private String filmArea;

    @ApiModelProperty(value = "片长,分钟数")
    @TableField("film_deartion")
    private Integer filmDeartion;

    @ApiModelProperty(value = "出品公司")
    @TableField("film_produce_corp")
    private String filmProduceCorp;

    @ApiModelProperty(value = "年份")
    @TableField("film_year")
    private String filmYear;

    @ApiModelProperty(value = "上映日期")
    @TableField("film_show_date")
    private LocalDate filmShowDate;

    @ApiModelProperty(value = "下映日期")
    @TableField("film_show_end_date")
    private LocalDate filmShowEndDate;

    @ApiModelProperty(value = "二轮上映日期")
    @TableField("film_show_date2")
    private LocalDate filmShowDate2;

    @ApiModelProperty(value = "二轮下映日期")
    @TableField("film_show_end_date2")
    private LocalDate filmShowEndDate2;

    @ApiModelProperty(value = "二轮最低限价")
    @TableField("film_low_price2")
    private Double filmLowPrice2;

    @ApiModelProperty(value = "介绍")
    @TableField("film_desc")
    private String filmDesc;

    @ApiModelProperty(value = "票房")
    @TableField("film_box_office")
    private Integer filmBoxOffice;

    @ApiModelProperty(value = "评星")
    @TableField("film_star")
    private String filmStar;

    @ApiModelProperty(value = "评分")
    @TableField("film_score")
    private Double filmScore;

    @ApiModelProperty(value = "关注数")
    @TableField("film_care")
    private Integer filmCare;

    @ApiModelProperty(value = "一句话简介")
    @TableField("film_view_focus")
    private String filmViewFocus;

    @ApiModelProperty(value = "影片专资code 第四位用a替换掉了")
    @TableField("film_key")
    private String filmKey;

    @TableField("create_time")
    private LocalDateTime createTime;

    @TableField("update_time")
    private LocalDateTime updateTime;

    @ApiModelProperty(value = "未删除=0;已删除=1;")
    @TableField("del_flag")
    @TableLogic
    private Integer delFlag;

    @ApiModelProperty(value = "film_no 逗号分割")
    @TableField("film_no")
    private String filmNo;

    @ApiModelProperty(value = "默认空，1不同步影片，影片同步时防止手动修改被覆盖 ")
    @TableField("film_update")
    private Integer filmUpdate;


    @Override
    protected Serializable pkVal() {
        return this.id;
    }

}
